package com.course.bean;

import java.lang.reflect.InvocationTargetException;
import java.util.Map;

import com.course.formbean.CourseFormBean;
import com.sun.org.apache.commons.beanutils.BeanUtils;

public class CourseTo {

	
	
	private int courseid;
	private String cname;
  private String cdescription;
  private String cdate;
  private String cstatus;
  private String cfaculty;
  private String cstudent;
  private String login;
  private String material;
  private String mdate;
  
  private String mname;
  private String fname;
  private String lname;
  private int userid;
  private String email;
  private String fax;
  
  private int mid;
	
	
	
	public CourseTo(){
		}
	
	public CourseTo(CourseFormBean cb){
		
		
		
		try{
 			Map  map= BeanUtils.describe(cb);
 			BeanUtils.populate(this, map);
 		}
 		catch (IllegalAccessException e1) {
 			// TODO Auto-generated catch block
 			e1.printStackTrace();
 		} catch (InvocationTargetException e1) {
 			// TODO Auto-generated catch block
 			e1.printStackTrace();
 			
 		} catch (NoSuchMethodException e) {
 			// TODO Auto-generated catch block
 			e.printStackTrace();
 		}
 		}

	public int getCourseid() {
		return courseid;
	}

	public void setCourseid(int courseid) {
		this.courseid = courseid;
	}

	public String getCname() {
		return cname;
	}

	public void setCname(String cname) {
		this.cname = cname;
	}

	public String getCdescription() {
		return cdescription;
	}

	public void setCdescription(String cdescription) {
		this.cdescription = cdescription;
	}

	public String getCdate() {
		return cdate;
	}

	public void setCdate(String cdate) {
		this.cdate = cdate;
	}

	public String getCstatus() {
		return cstatus;
	}

	public void setCstatus(String cstatus) {
		this.cstatus = cstatus;
	}

	public String getCfaculty() {
		return cfaculty;
	}

	public void setCfaculty(String cfaculty) {
		this.cfaculty = cfaculty;
	}

	public String getCstudent() {
		return cstudent;
	}

	public void setCstudent(String cstudent) {
		this.cstudent = cstudent;
	}

	public String getLogin() {
		return login;
	}

	public void setLogin(String login) {
		this.login = login;
	}

	public String getMaterial() {
		return material;
	}

	public void setMaterial(String material) {
		this.material = material;
	}

	public String getMdate() {
		return mdate;
	}

	public void setMdate(String mdate) {
		this.mdate = mdate;
	}

	public String getMname() {
		return mname;
	}

	public void setMname(String mname) {
		this.mname = mname;
	}

	public String getFname() {
		return fname;
	}

	public void setFname(String fname) {
		this.fname = fname;
	}

	public String getLname() {
		return lname;
	}

	public void setLname(String lname) {
		this.lname = lname;
	}

	public int getUserid() {
		return userid;
	}

	public void setUserid(int userid) {
		this.userid = userid;
	}

	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public String getFax() {
		return fax;
	}

	public void setFax(String fax) {
		this.fax = fax;
	}

	public int getMid() {
		return mid;
	}

	public void setMid(int mid) {
		this.mid = mid;
	}
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
}
